<?php
/*
 * @ https://EasyToYou.eu - IonCube v11 Decoder Online
 * @ PHP 7.2 & 7.3
 * @ Decoder version: 1.1.6
 * @ Release: 10/08/2022
 */

// Decoded file for php version 71.
namespace app\card\model;

class CardForward extends \app\BaseModel
{
    protected $name = "longbing_card_forward";
    protected static function init()
    {
    }
    public function getCount($where)
    {
        $data = $this->field("staff_id as user_id,count(staff_id) as number,uniacid")->whereDay("create_time", "yesterday")->group("staff_id")->where($where)->select()->toArray();
        if($data) {
            foreach ($data as $key => $val) {
                $data[$key]["table"] = "forward";
                $data[$key]["create_time"] = strtotime("-1 day");
            }
            $stat = new \app\dynamic\model\CardStatistics();
            $stat->createRows($data);
        }
        return $data;
    }
    public function getYesterday($where)
    {
        return $this->where($where)->whereDay("create_time", "yesterday")->count();
    }
    public function forwardCount($where4)
    {
        return $this->where($where4)->count();
    }
}

?>